package util;
import java.lang.*;
import java.sql.Connection;
import java.sql.DriverManager;
public class JDBCUtil {
    public static Connection getConnection() throws Exception{
        Class.forName("com.mysql.cj.jdbc.Driver");
        String url1 = "jdbc:mysql://localhost:3306/atm?useSSL=false&useUnicode=true&characterEncoding=utf-8&serverTimezone=Asia/Shanghai&allowPublicKeyRetrieval=true";
        String url2 = "jdbc:mysql://127.0.0.1:3306/atm?useSSL=false&useUnicode=true&characterEncoding=utf-8&serverTimezone=Asia/Shanghai&allowPublicKeyRetrieval=true";
        String password = "lyt958524377394";
        String user = "root";

        return DriverManager.getConnection(url1,user,password);
    }

    public void release(){

    }

}
